<?php
namespace app\model;
use app\BaseModel;
use think\model\concern\SoftDelete;
use app\model\Member;

class MemberCert extends BaseModel
{

    use SoftDelete;
    protected $deleteTime = 'delete_time';
    protected $defaultSoftDelete = '0000-00-00 00:00:00';
    protected $hidden = ['update_time','delete_time','sort'];







    protected function setMemberIdAttr($value,$data){ //当前字段的修改器
         $member = Member::where('id',$value)->find();
         $this->set('member_mobile',$member['mobile']);
         $this->set('member_name',$member['name']);
         return $value;
    }





}